package com.cloudlead.plugin.scheduler.query;

import static com.mysema.query.types.PathMetadataFactory.*;

import com.cloudlead.plugin.scheduler.entity.EScheduleJob;
import com.cloudlead.plugin.scheduler.entity.EScheduleJobInstance;
import com.cloudlead.plugin.scheduler.entity.EScheduleJobParams;


import com.mysema.query.types.path.*;

import com.mysema.query.types.PathMetadata;
import javax.annotation.Generated;
import com.mysema.query.types.Path;

import com.mysema.query.sql.ColumnMetadata;
import java.sql.Types;

import com.mysema.query.sql.*;

import com.cloudlead.common.lang.annotation.Label;


/**
 * QScheduleJob is a Querydsl query type for EScheduleJob
 */
@Label("计划任务查询")
@Generated("com.cloudlead.utils.persistence.codegen.serializer.SimpleMetaDataSerializer")
public class QScheduleJob extends RelationalPathBase<EScheduleJob> {

    private static final long serialVersionUID = -2065160863;

    public static final QScheduleJob scheduleJob = new QScheduleJob("schedule_job");

    public class PrimaryKeys {

        public final PrimaryKey<EScheduleJob> primary = createPrimaryKey(id);

    }

    public class ForeignKeys {

        public final ForeignKey<EScheduleJobInstance> _jobInstanceJob1Fk = createInvForeignKey(id, "job_id");

        public final ForeignKey<EScheduleJobParams> _jobParamsJob1Fk = createInvForeignKey(id, "job_id");

    }

    public final StringPath cron = createString("cron");

    public final NumberPath<Long> endTime = createNumber("endTime", Long.class);

    public final StringPath exec = createString("exec");

    public final StringPath execType = createString("execType");

    public final StringPath id = createString("id");

    public final StringPath name = createString("name");

    public final NumberPath<Long> startTime = createNumber("startTime", Long.class);

    public final StringPath status = createString("status");

    public final StringPath username = createString("username");

    public final PrimaryKeys pk = new PrimaryKeys();

    public final ForeignKeys fk = new ForeignKeys();

    public QScheduleJob(String variable) {
        super(EScheduleJob.class, forVariable(variable), "null", "schedule_job");
        addMetadata();
    }

    public QScheduleJob(String variable, String schema, String table) {
        super(EScheduleJob.class, forVariable(variable), schema, table);
        addMetadata();
    }

    public QScheduleJob(Path<? extends EScheduleJob> path) {
        super(path.getType(), path.getMetadata(), "null", "schedule_job");
        addMetadata();
    }

    public QScheduleJob(PathMetadata<?> metadata) {
        super(EScheduleJob.class, metadata, "null", "schedule_job");
        addMetadata();
    }

    public void addMetadata() {
        addMetadata(cron, ColumnMetadata.named("cron").withIndex(3).ofType(Types.VARCHAR).withSize(255));
        addMetadata(endTime, ColumnMetadata.named("end_time").withIndex(5).ofType(Types.BIGINT).withSize(19));
        addMetadata(exec, ColumnMetadata.named("exec").withIndex(8).ofType(Types.LONGVARCHAR).withSize(65535).notNull());
        addMetadata(execType, ColumnMetadata.named("exec_type").withIndex(7).ofType(Types.CHAR).withSize(11).notNull());
        addMetadata(id, ColumnMetadata.named("id").withIndex(1).ofType(Types.CHAR).withSize(24).notNull());
        addMetadata(name, ColumnMetadata.named("name").withIndex(2).ofType(Types.VARCHAR).withSize(255).notNull());
        addMetadata(startTime, ColumnMetadata.named("start_time").withIndex(4).ofType(Types.BIGINT).withSize(19));
        addMetadata(status, ColumnMetadata.named("status").withIndex(9).ofType(Types.CHAR).withSize(12));
        addMetadata(username, ColumnMetadata.named("username").withIndex(10).ofType(Types.VARCHAR).withSize(255));
    }

}

